package com.wf.pattern.factory.abstractfactory;

import com.wf.pattern.factory.abstractfactory.impl.FarmA;
import com.wf.pattern.factory.abstractfactory.impl.FarmB;

/**
 * 功能描述
 *
 * @since 2021/11/3
 */
public class Main {
    public static void main(String[] args) {
        FarmFactory farmA = new FarmA();
        FarmFactory farmB = new FarmB();
        Animal animal = farmA.newAnimal();
        animal.show();
        farmA.newPlant().show();

        farmB.newPlant().show();
        farmB.newAnimal().show();
    }
}
